<%@page import="com.tubeonfire.entity.Tube"%>
<%@page import="com.google.appengine.api.datastore.Text"%>
<%@page import="com.tubeonfire.entity.Playlist"%>
<%@page import="java.util.*"%>
<%@page import="com.google.appengine.api.users.UserService"%>
<%@page import="com.google.appengine.api.users.UserServiceFactory"%>
<%@page import="com.google.appengine.api.blobstore.BlobstoreServiceFactory"%>
<%@page import="com.google.appengine.api.blobstore.BlobstoreService"%>
<%
	BlobstoreService blobstoreService = BlobstoreServiceFactory
			.getBlobstoreService();
%>
<%
   	Playlist pl = (Playlist) request.getAttribute("result");
	request.setCharacterEncoding("UTF-8");	
	String url = request.getRequestURI();	
	String title = "Edit Playlist Videos - TubeOnFire";
	String description = "Mix something from youtube. Create an video playlist in seconds";
	String keyword = "video clip, youtube, mix clip, tubeonfire.com, tubeonfire, your clip...";
%>
<jsp:include page="/element/header.jsp">	
	<jsp:param name="url" value="<%= url %>"/>
	<jsp:param name="title" value="<%=title %>"/>	
	<jsp:param name="keywords" value="<%=keyword %>"/>
	<jsp:param name="description" value="<%=description %>"/>
</jsp:include>
<div class="clear"></div>    
<section id="wrapper">		
	<div class="column-full">
	<br />        	
		<div class="page_wrap">
		<div class="page_container box_alignleft sidebox">
			<div class="one" style="margin:5px 5px;">
				<h2 class="title-line alignright">Managing <%= pl.getTitle().getValue()%></h2>
				<br> <br> 												
				<div class="formul">
						 <div class="tbhead"><h5><%=pl.getTitle().getValue() %></h5></div>
						
						<table cellpadding="0" cellspacing="0" width="100%" class="tableStatic">
						
						    <thead>
						
						        <tr>						
									<td width="5%">Cover</td>
									<td width="85%">Title</td>									
									<td width="10%">Options</td>		
								</tr>
						
							</thead>
						
						    <tbody>
						
							<%
								if(pl.getListTubes().size()>0){
									for(Text textPlayList: pl.getListTubes()){
										Tube tub = new Tube();
										tub.transformString(textPlayList.getValue());
							%>
						<tr>		
							<td>
								<a href="/video/<%=tub.getTubeId() %>/<%=tub.getAlias().getValue() %>.html">
									<img src="<%=tub.getThumbImageUrl().getValue() %>" width="60" heaight="40">
								</a>
							</td>
							<td>
							<p>
								<%=tub.getTitle().getValue() %>
							</p>						
							
							</td>											
						
							<td>
								<div class="button-group">						
								<a href="/playlist/remove_clip?id=<%=tub.getTubeId() %>&pId=<%=pl.getId() %>" onclick="return confirm('Are you sure want to remove this video ?')" title="Are you sure you want to delete this video?" class="button red on icon delete">Delete</a>
								</div>
							 </td>		
						
						</tr>
						
						<%
							}
									}
							
							%>
							
						
						
							</tbody>
						
						</table> 
						</div>
				<br>
				  						
				</div>
			</div>
			
			<div class="page_sidebox box_alignfull">

<div class="follow_us">
<div class="follow_social">
    <div class="iconBox">
    <a href="http://twitter.com/Marius_SEO" target="_blank"><div class="twitter" title="Yeah, stalking is allowed!"></div></a>
 <span>
 <div class="follow-text">Follow us</div>
 </span>
 </div>
 <div class="iconBox">
<a href="http://www.facebook.com/videosoft" target="_blank"><div class="facebook" title="Be one of our happy fans"></div></a>
 <span>
<div class="follow-text">Be a Fan</div>
 </span>
 </div>
<div class="iconBox">
 <a href="http://videoinedit.com/rss.php" target="_blank"><div class="feedburner" title="Get fresh videos on your e-mail!"></div></a>
 <span>
<div class="follow-text">Subscribe</div>
 </span>
 </div>
</div>
</div>

<jsp:include page="/element/channels.jsp"/>
<jsp:include page="/element/categories.jsp"/>		
<jsp:include page="/element/advertising_right01.jsp"/>	
<jsp:include page="/element/playlist.jsp"/>	
</div>
<!-- end pv-sidebox --></div>
</div>
<div class="clear"></div>

<jsp:include page="/element/advertising_right02.jsp"/>	
<jsp:include page="/element/footer.jsp"/>	
			
		
		






